/**
 * Creat with IntelliJ IDEA
 * Description:
 * User:WZW
 * Date:2022-04-18
 * Time:20:43
 */

public class Demo5 {

    private static final long count = 10_0000_0000;

    public static void serial() {
        //记录程序执行时间
        long beg = System.currentTimeMillis();
        long a = 0;
        for (int i = 0; i < count; i++) {
            a++;
        }
        long b = 0;
        for (int i = 0; i < count; i++) {
            b++;
        }
        long end = System.currentTimeMillis();
        System.out.println("执行时间：" + (end - beg) + "ms");
    }

    public static void main(String[] args) {
        serial();
    }
}
